home *** CD-ROM | disk | FTP | other *** search
/ Software of the Month Cl… (Business) 1997 November / Software of the Month Club - Business Shareware (Volume 243) (November 1997).iso / dos / biz / Parse / EXAMPL05.POM < prev    next >
Encoding:
Text File  |  1997-08-27  |  653 b   |  27 lines

  1. ;
  2. ;   Divide up the input line because it is more than 255 characters wide
  3. ;
  4. SPLIT    005-100    102-168    170-300
  5. ;
  6. ;   Extract the fields
  7. ;
  8. IF       LineNum = ""  THEN Name    = $FLUPC[ 1  35]
  9. IF       LineNum = "1" THEN Phone   = $FLINE[53  67]
  10. IF       LineNum = "2" THEN Descrip = $FLINE[ 1  76]
  11. ;
  12. ;   Remove surrounding spaces
  13. ;
  14. TRIM     Name     "B"  " "
  15. TRIM     Phone    "B"  " "
  16. TRIM     Descrip  "B"  " "
  17. ;
  18. ;   Build the line
  19. ;
  20. OUT      LineNum = ""  |"{Name}",
  21. OUT      LineNum = "1" |"{Phone}",
  22. OUTEND   LineNum = "2" |"{Descrip}"
  23. ;
  24. ;   Reset line counter
  25. ;
  26. IF       LineNum = "2" THEN LineNum = "" ELSE LineNum+
  27.